<template>
  <div class="home">
    <main>
      <el-container>
        <el-header>
          <Elheaders></Elheaders>
        </el-header>
        <el-container>
          <el-aside>
            <asideLeft></asideLeft>
          </el-aside>
          <el-container>
            <el-main>
              <router-view></router-view>
            </el-main>
            <el-footer>
              <ElFooter></ElFooter>
            </el-footer>
          </el-container>
        </el-container>
      </el-container>
    </main>
  </div>
</template>

<script>
import asideLeft from "@/views/aside/index";
import Elheaders from "@/views/Headers/index";
import ElFooter from '@/views/Footer/index'

export default {
  name: "home",
  components: {
    asideLeft,
    Elheaders,
    ElFooter
  },
  created() {

    if (this.$route.fullPath=='/'){
      this.$router.push('/homeView')
    }
  }
}
</script>

<style scoped lang="scss">
.home {
  height: 100%;

  main {
    height: 100%;
  }

  .el-header, .el-footer {
    //background-color: #B3C0D1;
    color: #333;
    text-align: center;
    line-height: 60px;
    margin: 0;
    padding: 0;
  }

  .el-container.is-vertical {
    height: 100%;
  }

  .el-aside {
    background-color: #D3DCE6;
    color: #333;
    text-align: center;
    line-height: 200px;
    width: 160px !important;
  }

  .el-main {
    background-color: #E9EEF3;
    color: #333;
    text-align: center;
    //line-height: 160px;
  }

  body > .el-container {
    margin-bottom: 40px;
  }

  //.el-container:nth-child(5) .el-aside,
  //.el-container:nth-child(6) .el-aside {
  //  line-height: 260px;
  //}
  //
  //.el-container:nth-child(7) .el-aside {
  //  line-height: 320px;
  //}
}
</style>